package csdn.jihe.li12;

import java.util.HashMap;
import java.util.Map;

public class Test {
    public static void main(String[] args) {

        Map<Student,String> map=new HashMap<>();

        map.put(new Student("李霄",18), "购物袋");//注意重写hashCode和equals--hashMap在添加值时先调用hashCode再调用equals
        map.put(new Student("男霄",18), "男");
        map.put(new Student("女霄",18), "女");



    }
}
